﻿//using MultiAgentsShared;

//namespace MultiAgents.Scripts.Services
//{
//    public class ChatRoomComProtocolService
//    {
//        private readonly ChatChainModel _chatChainModel;

//        public ChatRoomComProtocolService(ChatChainModel chatChainModel)
//        {
//            _chatChainModel = chatChainModel;
//        }


//        [GptFunc("Used to vote for chat room completion in order to move to next phase of developer", typeof(CudaCodeConvertTeamToolSetsConfig))]
//        public string VoteForChatRoomCompletion(
//            [GptFuncParam("Yourself")]
//                string agent,
//            [GptFuncParam("if you would like the current meeting to end. True to end it, False to continue with the meeting")]
//                bool voteForCompletion)
//        {
//            foreach (var chatRoom in _chatChainModel.CurChatStep.chatRooms)
//            {
//                //TODO: issue as multiple room might be in a step and they might share agent
//                if (chatRoom.ChatRoomCompleted == false && chatRoom.agentRequired.Any(a => a.agentEnum == agent))
//                {
//                    chatRoom.VoteForChatRoomCompletion(agent, voteForCompletion);
//                    return "Vote Made.";
//                }
//            }

//            return "Failed to find chatRoom to vote for.";
//        }

//    }
//}
